<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>模块化</title>
  </head>
  <body>
    <script type="module">
      // 1.通用的导入方式
      import * as m from "./36_m.js";
      console.log(m);
      m.default.speak();

      // 2.结构赋值形式
      import { name, tech } from "./36_m.js";
      console.log(name, tech);

      // 3.简便形式，只针对默认暴露
      import m1 from "./36_m.js";
      console.log(m1);
    </script>
  </body>
</html>
